Inferring Cost Equations for Recursive, Polymorphic and Higher-Order Functional Programs

نویسندگان

  • Pedro B. Vasconcelos
  • Kevin Hammond
چکیده

This paper presents a type-based analysis for inferring sizeand cost-equations for recursive, higher-order and polymorphic functional programs without requiring user annotations or unusual syntax. Our type reconstruction algorithm is capable of inferring cost equations for a subset of recursive programs whose costs can be expressed using primitive recursion. We illustrate the approach with reference to some standard examples of recursive programs.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Static Dependency Pair Method in Rewriting Systems for Functional Programs with Product, Algebraic Data, and ML-Polymorphic Types

For simply-typed term rewriting systems (STRSs) and higher-order rewrite systems (HRSs) à la Nipkow, we proposed a method for proving termination, namely the static dependency pair method. The method combines the dependency pair method introduced for first-order rewrite systems with the notion of strong computability introduced for typed λ-calculi. This method analyzes a static recursive struct...

متن کامل

On the Pursuit of Static and Coherent Weaving

Aspect-oriented programming (AOP) has been shown to be a useful model for software development. Special care must be taken when we try to adapt AOP to strongly typed functional languages which come with features like type inference mechanism, polymorphic types, higher-order functions and type-scoped pointcuts. Specifically, it is highly desirable that weaving of aspect-oriented functional progr...

متن کامل

Origami programming

3 origami (˛ orig¯ a·mi) The Japanese art of making elegant designs using folds in all kinds of paper. One style of functional programming is based purely on recursive equations. Such equations are easy to explain, and adequate for any computational purpose , but hard to use well as programs get bigger and more complicated. In a sense, recursive equations are the 'assembly language' of function...

متن کامل

Higher-Order Value Flow Graphs

The concepts of value-and control-ow graphs are important for program analysis of imperative programs. An imperative value ow graph can be constructed by a single pass over the program text. No similar concepts exist for higher-order languages: we propose a method for constructing value ow graphs for typed higher-order functional languages. A higher-order value ow graph is constructed by a sing...

متن کامل

Types for Deadlock-Free Higher-Order Concurrent Programs

Deadlock freedom is for concurrent programs what progress is for sequential ones: it indicates the absence of stable (i.e., irreducible) states in which some pending operations cannot be completed. In the particular case of communicating processes, operations are inputs and outputs on channels and deadlocks may be caused by mutual dependencies between communications. In this work we define an e...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2003